home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1993 July / InfoMagic USENET CD-ROM July 1993.ISO / sources / misc / volume16 / gnuplot2.02 / patch1 next >
Encoding:
Internet Message Format  |  1991-01-05  |  13.9 KB

  1. From: rjl@monu1.cc.monash.edu.au (Russell Lang)
  2. Newsgroups: comp.sources.misc
  3. Subject: v16i011:  Gnuplot 2.0 patch 2, 1 of 7
  4. Message-ID: <1991Jan5.034916.2294@sparky.IMD.Sterling.COM>
  5. Date: 5 Jan 91 03:49:16 GMT
  6. Approved: kent@sparky.imd.sterling.com
  7. X-Checksum-Snefru: cc4c6a33 4c36589c 930b5d43 552d2bc1
  8.  
  9. Submitted-by: Russell Lang <rjl@monu1.cc.monash.edu.au>
  10. Posting-number: Volume 16, Issue 11
  11. Archive-name: gnuplot2.02/patch1
  12. Patch-To: gnuplot2.0: Volume 11, Issue 65-79
  13.  
  14. #! /bin/sh
  15. # This is a shell archive.  Remove anything before this line, then unpack
  16. # it by saving it into a file and typing "sh file".  To overwrite existing
  17. # files, type "sh file -c".  You can also feed this as standard input via
  18. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  19. # will see the following message at the end:
  20. #        "End of shell archive."
  21. # Contents:  README2.patch
  22. # Wrapped by eln272v@monu1 on Wed Dec 19 11:57:07 1990
  23. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  24. if test -f README2.patch -a "${1}" != "-c" ; then 
  25.   echo shar: Will not over-write existing file \"README2.patch\"
  26. else
  27. echo shar: Extracting \"README2.patch\" \(12252 characters\)
  28. sed "s/^X//" >README2.patch <<'END_OF_README2.patch'
  29. XREADME2.patch - some notes about gnuplot 2.0 patchlevel 2.
  30. X
  31. XThe major additions in this patch are parametric functions,
  32. XX11 Motif support, new bit mapped graphics routines, and new terminal 
  33. Xdrivers vttek (VT like tektronix emulators), hpljii (HP LaserJet II), 
  34. Xkyo (Kyocera Laser Printer), SCO CGI.  
  35. XFor a more complete list of the changes, see the MODIFICATIONS
  36. Xsection below.
  37. X
  38. X
  39. XAPPLYING PATCH 2
  40. X----------------
  41. X
  42. XTo apply this patch copy the files README2.patch, patch2a, patch2b, 
  43. Xpatch2c, patch2d, patch2e and patch2f to the gnuplot directory.  
  44. XChange directory to the gnuplot directory, and then apply the patch with 
  45. Xthe following commands:
  46. X
  47. X    rm term/font5x7.trm
  48. X    rm term/eps60.trm
  49. X    rm term/hpljet.trm
  50. X    rm term/epson.trm
  51. X    mv README.patch1 README1.patch
  52. X    patch -p < patch2a
  53. X    patch -p < patch2b
  54. X    patch -p < patch2c
  55. X    patch -p < patch2d
  56. X    patch -p < patch2e
  57. X    patch -p < patch2f
  58. X
  59. X    Copy the appropriate makefile.* to Makefile, READ THE Makefile
  60. X    and make any necessary changes. Then recompile!
  61. X
  62. X
  63. XMAIL ADDRESSES
  64. X--------------
  65. X
  66. XThe mailing list info-gnuplot exists as a forum for discussions about 
  67. Xgnuplot.  About the only gnuplot topic not supported by this list is 
  68. Xbug reports.  They are handled by a different mail alias, bug-gnuplot.  
  69. X
  70. XTo be removed or add someone to the mailing list send mail to:
  71. X
  72. Xpixar!info-gnuplot-request@sun.com
  73. X
  74. X
  75. XTo report bugs send mail to:
  76. X
  77. Xpixar!bug-gnuplot@sun.com
  78. X
  79. X
  80. XTo ask a question or discuss gnuplot send mail to:
  81. X
  82. Xpixar!info-gnuplot@sun.com
  83. X
  84. X
  85. Xpixar is a UUCP site.  sun.com is a UUCP and Internet site.  
  86. XIn the above addresses, sun.com can be replaced by ucbvax.berkeley.edu.
  87. X
  88. X
  89. XPARAMETRIC IMPLEMENTATION
  90. X-------------------------
  91. X
  92. XAt the request of Bill Schulz, one of our illustrious math profs, I
  93. Xwas "encouraged" to build parametric plotting capability into gnuplot.
  94. XHe not only explained how much more useful parametric plotting was
  95. Xcompared to the simpler case of function plotting, but he suggested
  96. Xthe syntax for parametric plots as simply x,y pairs of functions on
  97. Xthe plot line.  (He also suggested that the changes must be very easy
  98. Xto do, but I forgive him for that bit of chicanery.)
  99. X
  100. XThus armed, I was surprised at the number of other issues I ran into.
  101. XFor instance, in addition to inventing a `set parametric' command I
  102. Xtook a hard look at xrange and yrange and decided I also 
  103. Xneeded a trange when in parametric mode.  This, happily, led
  104. Xto what I believe is the right behavior in all cases I have tested
  105. Xfor parametric equations.  Indeed, I feel the implementation is
  106. Xbetter than I originally hoped for as you can, in parametric mode,
  107. Xcontrol the t range, x range and y range independently.  This gives
  108. Xyou quite a bit of control over the function being plotted.
  109. X
  110. XIf the parametric commentary seems to be too verbose I'm willing to shorten 
  111. Xit on command.  (I normally don't write like that--geesh!)  I'm happy to 
  112. Xleave it alone, however, if no one finds it offensive.
  113. XOf course, to be complete I needed an autoscale_t variable (such already
  114. Xexisted for x and y).  The meaning of this variable, however, was a bit
  115. Xweak.  Internally it is necessary, but from the user's standpoint,
  116. Xit may not make much sense to have a `set autoscale t' command.  All that
  117. Xgains the user is a chance to catch an empty trange and expand it if
  118. Xnecessary.  How an empty trange comes into existence is a mystery
  119. Xto me.  (Empty x ranges can occur, I guess, due to a data file or
  120. Xbeing in polar mode.)
  121. X
  122. XThe trange, by the way, has an arbitrary default of [-5:5] (whereas
  123. Xthe xrange default is [-10:10]).  This was a range suggested by Bill
  124. XSchulz when I pinned him down on what would be "reasonable" one day.
  125. XIf you can think of any reason for any other range please let me know.
  126. XThe current range has the habit, by the way, of plotting over cyclic
  127. Xfunctions defined on [0:2*pi] such that dashed lines don't look good.
  128. XThere seems to be no real "solution" other than to avoid the default
  129. Xrange where it doesn't make any sense.
  130. X
  131. XPlotting, as described in my additions to gnuplot.doc, in parametric
  132. Xmode requires pairs of functions.  Consider the following:
  133. X
  134. Xplot [-3:3] [0:20] [-10:20] sin(t),t**2,'data.file',t,t**2
  135. X
  136. Xwhich has a trange of [-3:3] an xrange of [0:20] and a yrange of [-10:20].
  137. XThe plot consists of 3 curves: sin(t),t**2; the 'data.file' points;
  138. Xand the plot of t,t**2.  The last, of course, could be done in 
  139. Xnon-parametric mode as simply x**2.  In parametric mode, you have to
  140. Xbe finished defining a parametric pair (an x-function and a y-function)
  141. Xbefore you can put in a `with' or `title' modifier.
  142. X
  143. XRanges can be set on the plot command or with the `set [xyt]range'
  144. Xcommand.  As an added benefit, when in parametric mode, the xrange
  145. Xcan be autoscaled.  This is true because, like the yrange, the xrange
  146. Xis now a computed entity.
  147. X
  148. XFinally, I decided that the data file, as ordered (x,y) pairs, could affect 
  149. Xthe xrange but not the trange.  Hence plotting the following:
  150. X
  151. Xplot sin(t),cos(t),'data.file'
  152. X
  153. XWhere 'data.file' only has points in the positive x range will cause
  154. Xthe plot of sin(t),cos(t) to take on x values only in the positive
  155. Xx range.  Another option was to make 'data.file' x values affect the
  156. Xworking t range of the parametric function.  This did not seem like
  157. Xa good idea, however, and some effort was made to avoid this affect.
  158. XThe best plan might have been to ignore the 'data.file' ranges
  159. Xall together when in parametric mode.  I hope someone will think
  160. Xon this issues and voice an opinion at some point in the future.
  161. X
  162. X
  163. XUNFINISHED ISSUES
  164. X
  165. XThere are some unfinished issues that I ran across in doing the parametric 
  166. Ximplementation.  These are not so much parametric related issues as 
  167. Xthey are general gnuplot issues that the parametric work brought to the 
  168. Xforefront.
  169. X
  170. XFirst, what is the use of global xmin and xmax changes when a
  171. Xdata file is plotted?  In other words, why would xmin and xmax
  172. Xchange for the whole session when the data file was just mentioned
  173. Xonce on a command line.  It seems that this global behavior is
  174. Xunwarranted.  The routine in question, get_data() simply checks 
  175. Xagainst the global xmin,xmax rather than the local x_min, x_max
  176. Xthat eval_plots() will eventually pass on to do_plot().  The change
  177. Xwouldn't be hard to do, and I'm hoping someone will decide it is
  178. Xa good idea for a later bug patch.
  179. X
  180. XAlso, the default style for each individual plot depends upon the
  181. Xline_type and point_type of the plot.  Gnuplot currently increments
  182. Xthe line_type (and possibly point_type) for each plot that it is
  183. Xplotting regardless of the type of plot in question.  For instance,
  184. Xplot x,'data.file',x**2 will generate x with line_type of 1 and
  185. Xx**2 with line_type of 3 while plot x,x**2,'data.file' will use a
  186. Xline_type of 1 and 2 respectively.  This also seemed expedient, but
  187. Xnot quite right in terms of what would be nicest behavior.  It seems
  188. Xto me that line_type's are scarce resources and should be used 
  189. X(incremented) only as needed.  In other words, since the 'data.file'
  190. Xplot isn't using a line_type at all, the second line_type should be
  191. Xsaved for the x**2 plot, and the two plots would look the same
  192. Xinstead of being different as they are now.
  193. X
  194. XOf course, neither of these issues are critical.  We've been living with
  195. Xthem comfortably for the whole life of at least the latest gnuplot 2.0
  196. Xrelease.  It seems to me, however, that both these problems are minor
  197. Xoversights and could easily be corrected in the near future.  Rather
  198. Xthan do that here, as part of the parametric work, I decided that would
  199. Xbe a change to the previous non-parametric behavior and should not be
  200. X"snuck in" without a bit of debate.
  201. X
  202. XJohn Campbell   jdc@naucse.cse.nau.edu   or CAMPBELL@NAUVAX.bitnet
  203. X
  204. X
  205. XSCO CGI DRIVERS 
  206. X---------------
  207. Xcopyright 1990 Ronald Florence
  208. X
  209. XThe 'cgi' driver added to Gnuplot 2.0 will work with the SCO CGI drivers.
  210. XTo use the CGI drivers, you will need to have the CGIPATH and CGIDISP 
  211. Xand/or CGIPRNT environmental variables declared.  The CGI output mode 
  212. Xcan be controlled by setting an ASPECT environmental variable.  The 
  213. Xdefault is to use full-screen/full-page.
  214. X
  215. XTwo CGI terminal options are provided.  If you have either CGIDISP or
  216. XCGIPRNT declared, Gnuplot 2.0 will start with terminal set to "cgi".
  217. XIf both devices are declared, you can "set terminal hcgi" to select
  218. Xthe CGIPRNT (hardcopy) device instead of the default CGIDISP device.
  219. XThis is useful when you are proofing a graph on the display before
  220. Xsending output to a printer or plotter.
  221. X
  222. XThe driver has been tested with the SCO vga, ega, cga, hercules, and
  223. Xlaserjet drivers.  If you are using a monochrome VGA display you may
  224. Xneed to include "-DVGA_MONO" in your Makefile to work-around the
  225. Xbroken SCO monochrome VGA display drivers.  The CGI driver includes 
  226. Xa built-in pause-for-any-key feature which makes the Gnuplot
  227. X"pause -1 prompt" command redundant.
  228. X
  229. XPermission is hereby granted for unlimited non-commercial use of this
  230. Xcode, on condition that the copyright notices are left intact and any
  231. Xmodifications to the source code are noted as such.  No warranty of
  232. Xany kind is implied or granted for this material.
  233. X
  234. XPlease send suggestions and comments to ron@mlfarm.com.
  235. X
  236. X
  237. XMODIFICATIONS IN PATCH 2.
  238. X-------------------------
  239. X
  240. XTony McGrath <phs145p@vaxc.cc.monash.edu.au>
  241. X  Fixed replot line length calculation (command.c).
  242. X
  243. XJohn Engel <jengels@bnandp51.bitnet>
  244. X  vttek terminal driver (term/tek.trm).
  245. X  vms additions for tektronix drivers (term.c).
  246. X  hpljii driver - now uses the same bitmap routines as the epson driver
  247. X   and will work on a PC (term/hpljii.trm).
  248. X  
  249. XRussell Lang <rjl@monu1.cc.monash.edu.au>
  250. X  Created term.c function 'void reopen_binary()' for PC (term.c).
  251. X  Removed HPLJET driver.
  252. X  Added an error check for bad xrange when plotting functions -
  253. X   this came up when an attempt is made to plot an non-existent
  254. X   data file with x autorange, followed on the next command line
  255. X   by an attempt to plot a function (command.c).
  256. X  Added new bit mapped graphics (bitmap.h, bitmap.c, term.c,
  257. X   epson.trm, hpljii.trm).
  258. X  Removed PROPRINTER driver - use epson_lx800 instead.
  259. X  nec_cp6 monochrome drivers also work with epson lq-800.
  260. X
  261. XRik Harris <edp367s@monu6.cc.monash.edu.au>
  262. X  Fixed 'set dummy' command (command.c).  
  263. X  Previously crashed if dummy variable missing.
  264. X
  265. XDave Kotz <dfk@cs.duke.edu>
  266. X  added x11 autosense code (term.c).
  267. X  empty gnuplot.doc lines now produce empty lines in .ms
  268. X   or .tex files.  (doc2ms.c, doc2tex.c)
  269. X  check for zero argument in call to x**(-n). (internal.c)
  270. X
  271. XJames Dugal <jpd@usl.edu>
  272. X  Fixed messy octal constants (epson.trm).
  273. X
  274. XJeff Kellem <composer@chem.bu.edu>
  275. X  Fixed ceil and floor to work as per documentation - for complex argument, 
  276. X   return integer ceil/floor of real part (standard.c).
  277. X  Changed gnuplot_x11.c to use default screen (gnuplot_x11.c).
  278. X
  279. XAnthony Thyssen <thyssen@batserver.cs.uq.oz.au>
  280. X  (Ideas by Anthony, code by Russell Lang)
  281. X  Changed 'plot with impulses' to draw impulses to origin (graphics.c).
  282. X  Added 'plot "datafile" using y|xy|yx "scanf string"' (command.c).
  283. X
  284. XGreg Montgomery <greg@turbo.atl.ga.us>
  285. X  Turbo C BGI drivers now use far code, to avoid segment _TEXT 
  286. X   overflow with TC++ (makefile.tc, linkopt.tc, plot.c).
  287. X
  288. XSebastian Kremer <sk@thp.Uni-Koeln.DE>
  289. X  Kyocera laser printer driver (term/kyo.trm).
  290. X
  291. XJohn Eaton <jwe@emx.utexas.edu>
  292. X  set [no][xy]zeroaxis  (graphics.c, setshow.c, setshow.h).
  293. X
  294. XJohn Campbell <jdc@naucse.cse.nau.edu>
  295. X  Parametric plots (command.c, misc.c, setshow.c, setshow.h).
  296. X
  297. XRonald Florence <ron@mlfarm.com>
  298. X  SCO CGI driver (term.c, term/cgi.trm).
  299. X
  300. XChip Rosenthal <chip@chinacat.Unicom.COM>
  301. X  Fixes a security problem with ".gnuplot" files (plot.c).
  302. X  Add pipe option for output file on Unix.  Can now say
  303. X  'set output "|more" '.
  304. X
  305. XEd Kubatis <ejk@uxh.cso.uiuc.edu>
  306. X  Ignore interrupts in gnuplot_x11.c (gnuplot_x11.c).
  307. X  Added X11 Motif support (gnuplot_x11.c).
  308. X  Demo files for 'plot using'.
  309. X  Added ifdef GETCWD for HP-UX (command.c).
  310. X  Fixed RS/6000 AIX 3.1 build problem (misc.c).
  311. X
  312. XRonald Hartranft <RJH2@NS.CC.Lehigh.EDU>
  313. X  Base work on new bit mapped graphics routines.
  314. X
  315. XAlex Woo <woo@pioneer.arc.nasa.gov>
  316. X  Changed -DGAMMA to -DGAMMA=gamma so that -DGAMMA=lgamma
  317. X  can be used on the NeXT (standard.c, makefiles).
  318. X
  319. XEnd of README2.patch
  320. END_OF_README2.patch
  321. if test 12252 -ne `wc -c <README2.patch`; then
  322.     echo shar: \"README2.patch\" unpacked with wrong size!
  323. fi
  324. # end of overwriting check
  325. fi
  326. echo shar: End of shell archive.
  327. exit 0
  328.  
  329. exit 0 # Just in case...
  330. -- 
  331. Kent Landfield                   INTERNET: kent@sparky.IMD.Sterling.COM
  332. Sterling Software, IMD           UUCP:     uunet!sparky!kent
  333. Phone:    (402) 291-8300         FAX:      (402) 291-4362
  334. Please send comp.sources.misc-related mail to kent@uunet.uu.net.
  335.